﻿using System;
using System.Collections.Generic;
using System.Web.Http;
using Smatime.Web.DAO;
using Smatime.Web.Models;

namespace Smatime.Web.Controllers
{
    public class TotalOfMonthController : ApiController
    {
        // GET 
        [Route("api/totalofmonth/companystaffid/{id}/month/{month}")]
        public IEnumerable<TotalOfMonth> GetTotalOfMonth(long id, DateTime month)
        {
            return new TotalOfMonthRepository().GetTotalWorkByStaffId(id, month);
        }

        // GET api/totalofmonth/5
        public string Get(int id)
        {
            return "value";
        }

        // POST api/totalofmonth
        public void Post([FromBody] string value)
        {
        }

        // PUT api/totalofmonth/5
        public void Put(int id, [FromBody] string value)
        {
        }

        // DELETE api/totalofmonth/5
        public void Delete(int id)
        {
        }
    }
}